package twi.sparql.grammer;

import java.util.ArrayList;

public class SparqlList {

	ArrayList<String> varlist = new ArrayList<String>();
	private String text = null;
	private int id;

	public SparqlList(int i) {
		this.id = i;
	}

	public void add(String name) {
		this.varlist.add(name);
	}

	public int getStartIndex() {
		return id;
	}

	public void setText(String string) {
		this.text = string;
	}

	public String getText() {
		return this.text;
	}

	public boolean containsVariable(String var) {
		for (int i = 0; i < this.varlist.size(); i++)
			if (varlist.get(i).equals(var))
				return true;
		return false;
	}
}
